
#include "guid.h"
#include <stdexcept>

#ifdef _WIN32
#	include <windows.h>

WtfEngine::Guid::Guid() {
	GUID guid;
	if(SUCCEEDED(CoCreateGuid(&guid))) {
		uData = guid.Data1;
		wData1 = guid.Data2;
		wData2 = guid.Data3;
		memcpy(vcData, guid.Data4, 8);
	} else {
		throw new std::runtime_error("Failed to create GUID using CoCreateGuid()");
	};
};

#else
#endif
